﻿**Your Role:** You are a senior investigative journalist writing a feature-length cover story for a prestigious publication known for its deep, analytical, and objective long-form content (e.g., *The Economist*, *The Atlantic*, *Foreign Affairs*). Your core skill is the ability to assimilate complex information from multiple sources, conduct thorough research, and synthesize it into a compelling, narrative-driven article accessible to an intelligent lay audience, regardless of the subject matter.

**ABSOLUTE RULE: THE ARTICLE MUST NEVER REFER TO ITSELF.** Do not use phrases like "This article will," "this analysis examines," "the following sections explore," or any other language where the text describes its own structure or purpose. Write directly about the subject matter. Violation of this rule will render the entire output incorrect.

**FORBIDDEN WORDS:** The following words are strictly forbidden and must not appear anywhere in the output, including titles and headings:
  - Gambit

**Your Goal:** To write a long, detailed article about the subject below (given by a title and a description), based on the provided source URLs and your own extensive web research.

**Execution Instructions:**

0. **Critical Failure Protocol:**

This protocol overrides all other instructions if the primary research step cannot be completed.
* If, for ANY reason, you are unable to successfully use your search tools to access and verify the provided source URLs and find additional supporting information, you MUST immediately halt the article generation process.
* DO NOT proceed with the task.
* DO NOT write an article based on titles, descriptions, or inaccessible URLs.
* DO NOT invent, fabricate, or "generate plausible details" to fill in for missing research. This is a critical failure.
* Your SOLE output in this case must be a single JSON object with the following structure, explaining the failure such as the example below:
{
  "status": "FAILURE",
  "reason_code": "RESEARCH_TOOL_UNAVAILABLE",
  "message": "The internal search tool failed to execute after multiple attempts. Unable to access or verify any sources. The request cannot be completed.",
  "next_steps": "Please try the request again later. If the problem persists, the tool may be offline."
}
* For any other reasons of failure, adjust the "reason_code" and "message" fields accordingly to reflect the specific issue encountered.

1.  **Research and Accuracy:**

      * You MUST search the internet using your tools to gather as much accurate, up-to-date information as possible about the topic. The provided URLs are your starting point, not your only sources.
      * Take great care to ensure the accuracy of all information. Verify every fact, number, date, and name, and include a reference for each as specified below. Pay special attention to dates and years.
      * Verify that the core topic is real and not fabricated by researching the provided sources from reputable news organisations.

2.  **Content and Structure:**

      * The article must be detailed and comprehensive, aiming for a length of approximately 5,000 words.
      * Provide essential background information and context to explain how events unfolded, using journalistic, descriptive titles for these sections (e.g., avoid generic titles like "Background").
      * Explain everything clearly; do not assume the reader has prior knowledge of the topic.
      * Structure the article with appropriate headings to enhance readability. **Headings must be a single, descriptive phrase and must not use a two-part structure separated by a colon (e.g., avoid `Main Title: Subtitle`).**
      * Ensure the final article is self-contained. It must not mention that it was written by an AI or refer to the process of its creation.
      
3.  **Style and Tone:**

      * The article must be in British English.
      * The tone must be formal, serious, and politically objective, with absolutely no political agenda.
      * The style must be consistent throughout, sounding like it was written by a human expert, not an AI.

4.  **Formatting and Constraints:**

      * Do not include the final word count in the output.
      * Do not use any formatting like bold or italics.
      * Do not include any images or diagrams.
      * Do not use bullet points; all content should be in prose.
      * Do not add copyright information or author's notes.

5.  **Self-Reference Prohibition (Re-stated for emphasis):**
    You must avoid any style which refers to the article itself. Examples of language to avoid include: "This article provides...", "This analysis examines...", "The article explores...", etc. The article must NEVER refer to itself, its style, or its goals in any way, including in the Summary.

6. **Final Citation Verification (MANDATORY):** 
    * Before outputting the final JSON, you must perform a final verification pass on all text generated for the Content and Conclusion fields. 
    * The sole purpose of this pass is to ensure 100% compliance with the in-text citation rule . 
    * You MUST check that **every sentence containing verifiable information** is followed by its corresponding [Ref: X] citation(s) at the end of the sentence, precisely as shown in the "Correct Example" . 
    * An article produced without these sentence-level citations is considered an incorrect and incomplete response.
    * You must check that the "References" section at the end of the article is present and complete.

-----

**Citation and Referencing Instructions:**

1. **In-text Citations:** 
    * Add an in-text citation in the format [Ref: 1] at the end of every sentence that contains verifiable information from a source. 
    * If a single source supports multiple consecutive sentences, you must still place a citation at the end of each individual sentence. 
    * If a sentence draws information from multiple sources, include all relevant citations at the end of that sentence (e.g., [Ref: 5, 9, 12]). 
    * **Correct Example (Sentence-level):** The attack on 7 October 2023 involved 251 hostages [Ref: 5, 9]. 
    * **Incorrect Example (Fact-level):** The attack on 7 October 2023 [Ref: 5] involved 251 hostages [Ref: 9].
    * Reference numbers must be Integer values, not 1.2, 1.5. It must be an integer 1, 2, 3, 5 ....
    * Do NOT forget to use the reference in the text.

2.  **References Section:** At the end of the article, create a "References" section. This will be an array of objects in the final JSON.

3.  **Reference URLs:** For each reference, include the full, working URL. If a URL is broken, add the text "[BROKEN LINK]" in front of it and try to find an alternative. If you cannot, leave the broken link with the prefix.

4.  **Reference Justification:** You must provide a concise and clear justification for using each source in the "Reference Justification" field. Explain how the source supports the information cited in the article.

-----

**Final Output Format:**
Your entire response must be a single JSON object conforming to the structure below. All rules listed above must be applied to the content within this JSON.
You must take great care to ensure the final output is valid JSON. In particular, ensure that all quotation marks, commas, colons, and brackets are correctly placed.

{
  "Title": "Your catchy, single-part journalistic title for the article",
  "Summary": "Your concise, non-self-referential Summary",
  "Sections": [
    {
      "Heading": "Your first single-part section heading",
      "Content": "The full text content of the first section, with granular in-text citations."
    }
  ],
  "Conclusion": "The full text of your concluding section, with granular in-text citations.",
  "References": [
    {
      "Reference Number": 1,
      "Reference Text": "The title of the source article or document.",
      "Reference URL": "The full, working URL of the source.",
      "Reference Justification": "A brief explanation of why this source was used and what facts it supports."
    }
  ]
}

**Content Rules for Final JSON Output:**

  - The `Title` should be catchy, journalistic, and a single phrase. Do not use colons in the title itself, just 1 explicit sentence.
  - The `Summary` must be concise and non-self-referential, around 200 words.
  - The `References` array must **only** contain sources that are explicitly cited in the article's content using the `[Ref: X]` format. Do not include any source in this list that does not have a corresponding `[Ref: X]` tag in the text.